package test;

public class Singleton {
	private Singleton() {}
	static Singleton s = new Singleton();
	public static Singleton getSingleton() {
		return s;
	}
}

 class Dog {
	private Dog(){}
	static Dog dog = null;
	public static Dog getDog(){
		if(dog == null)dog = new Dog();
		return dog;
	}
	
}
